package dao;

import org.apache.ibatis.annotations.Param;
import pojo.*;

import java.util.List;

public interface ProductMapper extends BaseMapper<Product>{
    Product getProduct(Product product);
    List<Product> getAllByPage1(Page<Product> page);
    int getCount1();
    int getProAdd(Product p);
    int getProupd(Product p);
    int getProDel(String productCode);
    PoItem getPoNum(PoItem poItem);
    Soitem getSoNum(Soitem soitem);
    int updatePoNumAdd(@Param("productCode") String productCode,@Param("num") int num);
    int updatePoNumDel(@Param("productCode") String productCode,@Param("num") int num);

    List<Product> productAllByPage(@Param("page") Page<Product> page, @Param("product") Product product);
    int ProductCount(@Param("page") Page<Product> page, @Param("product") Product product);
    List<Product> productAllByPage1(@Param("page1") Page<Product> page);
    int ProductCount1(@Param("page1") Page<Product> page);

    int addCheckstock(Checkstock checkstock);
    int updateNum(Product product);
    int addStockrecord(Stockrecord stockrecord);

    List<Stockrecord> outStockReportPage(@Param("page2") Page<Stockrecord> page, @Param("stock2") Stockrecord stockrecord);
    int outStockReportCount(@Param("page2") Page<Stockrecord> page, @Param("stock2") Stockrecord stockrecord);
    List<Stockrecord> outStockReportPage1(Stockrecord stockrecord);
    int outStockReportCount1(Stockrecord stockrecord);

    List<Stockrecord> inStockReportPage(@Param("page2") Page<Stockrecord> page, @Param("stock2") Stockrecord stockrecord);
    int inStockReportCount(@Param("page2") Page<Stockrecord> page, @Param("stock2") Stockrecord stockrecord);
    List<Stockrecord> inStockReportPage1(Stockrecord stockrecord);
    int inStockReportCount1(Stockrecord stockrecord);

    List<Stockrecord> stockChangePage(@Param("page3") Page<Stockrecord> page, @Param("stock3") Stockrecord stockrecord);
    int stockChangeCount(@Param("page3") Page<Stockrecord> page, @Param("stock3") Stockrecord stockrecord);
    List<Stockrecord> stockChangePage1(Stockrecord stockrecord);
    int stockChangeCount1(Stockrecord stockrecord);


    List<Payrecord>  getPayRecordInMoney(Payrecord payrecord);
    Integer getPayRecordInMoneyCount(Payrecord payrecord);
    List<Payrecord>  getPayRecordOutMoney(Payrecord payrecord);
    Integer getPayRecordOutMoneyCount(Payrecord payrecord);
    List<Payrecord> getPayRecord(@Param("page4") Page<Payrecord> page,@Param("stock4") Payrecord payrecord);
    Integer getPayRecordCount(@Param("page4") Page<Payrecord> page,@Param("stock4") Payrecord payrecord);
    List<Payrecord> getPayRecord1(@Param("page5") Page<Payrecord> page,@Param("stock5") Payrecord payrecord);
    Integer getPayRecordCount1(@Param("page5") Page<Payrecord> page,@Param("stock5") Payrecord payrecord);
    //    List<Payrecord> getPayRecordmonth(Payrecord payrecord);
//    int getPayRecordCountmonth(Payrecord payrecord);
//    List<Payrecord> getPayRecordmonth1(Payrecord payrecord);
//    int getPayRecordCountmonth1(Payrecord payrecord);
//    List<Payrecord> getPayRecord(@Param("page4") Page<Payrecord> page,@Param("date") String date);
//    int getPayRecordCount(String date);
//    List<Payrecord> getPayRecord1(@Param("page4") Page<Payrecord> page,@Param("date") String date);
//    int getPayRecordCount1(String date);
}
